package com.lzs.PO;

import java.util.ArrayList;
import java.util.List;

public class Member {

	private Integer id;
	
	private String family_id;
	
	private String rural_id;
	
	private String medical_card_id;
	
	private String member_id;
	
	private String member_name;
	
	private String relation;
	
    private String people_id;
    
    private String state;
    
    private Family family;
    
    private List<Certificate> certificateList = new ArrayList<Certificate>();

    
    
	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;
	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getFamily_id() {
		return family_id;
	}

	public void setFamily_id(String family_id) {
		this.family_id = family_id;
	}

	public String getRural_id() {
		return rural_id;
	}

	public void setRural_id(String rural_id) {
		this.rural_id = rural_id;
	}

	public String getMedical_card_id() {
		return medical_card_id;
	}

	public void setMedical_card_id(String medical_card_id) {
		this.medical_card_id = medical_card_id;
	}

	public String getMember_id() {
		return member_id;
	}

	public void setMember_id(String member_id) {
		this.member_id = member_id;
	}

	public String getMember_name() {
		return member_name;
	}

	public void setMember_name(String member_name) {
		this.member_name = member_name;
	}

	public String getRelation() {
		return relation;
	}

	public void setRelation(String relation) {
		this.relation = relation;
	}

	public String getPeople_id() {
		return people_id;
	}

	public void setPeople_id(String people_id) {
		this.people_id = people_id;
	}

	public Family getFamily() {
		return family;
	}

	public void setFamily(Family family) {
		this.family = family;
	}

	
	public List<Certificate> getCertificateList() {
		return certificateList;
	}

	public void setCertificateList(List<Certificate> certificateList) {
		this.certificateList = certificateList;
	}

	@Override
	public String toString() {
		return "Member [id=" + id + ", family_id=" + family_id + ", rural_id=" + rural_id + ", medical_card_id="
				+ medical_card_id + ", member_id=" + member_id + ", member_name=" + member_name + ", relation="
				+ relation + ", people_id=" + people_id + ", state=" + state + ", family=" + family
				+ ", certificateList=" + certificateList + "]";
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((family == null) ? 0 : family.hashCode());
		result = prime * result + ((family_id == null) ? 0 : family_id.hashCode());
		result = prime * result + ((medical_card_id == null) ? 0 : medical_card_id.hashCode());
		result = prime * result + ((member_id == null) ? 0 : member_id.hashCode());
		result = prime * result + ((member_name == null) ? 0 : member_name.hashCode());
		result = prime * result + ((people_id == null) ? 0 : people_id.hashCode());
		result = prime * result + ((relation == null) ? 0 : relation.hashCode());
		result = prime * result + ((rural_id == null) ? 0 : rural_id.hashCode());
		result = prime * result + ((state == null) ? 0 : state.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Member other = (Member) obj;
		if (family == null) {
			if (other.family != null)
				return false;
		} else if (!family.equals(other.family))
			return false;
		if (family_id == null) {
			if (other.family_id != null)
				return false;
		} else if (!family_id.equals(other.family_id))
			return false;
		if (medical_card_id == null) {
			if (other.medical_card_id != null)
				return false;
		} else if (!medical_card_id.equals(other.medical_card_id))
			return false;
		if (member_id == null) {
			if (other.member_id != null)
				return false;
		} else if (!member_id.equals(other.member_id))
			return false;
		if (member_name == null) {
			if (other.member_name != null)
				return false;
		} else if (!member_name.equals(other.member_name))
			return false;
		if (people_id == null) {
			if (other.people_id != null)
				return false;
		} else if (!people_id.equals(other.people_id))
			return false;
		if (relation == null) {
			if (other.relation != null)
				return false;
		} else if (!relation.equals(other.relation))
			return false;
		if (rural_id == null) {
			if (other.rural_id != null)
				return false;
		} else if (!rural_id.equals(other.rural_id))
			return false;
		if (state == null) {
			if (other.state != null)
				return false;
		} else if (!state.equals(other.state))
			return false;
		return true;
	}

	

	
    
}
